/************************************************************************

								Heroes IV
					  Copyright 2000, The 3DO Company

	------------------------------------------------------------------
  						       flotsam.h

	$Header: /game/flotsam.h $

	$NoKeywords: $

 ************************************************************************/

#ifndef FLOTSAM_H_INCLUDED
#define FLOTSAM_H_INCLUDED

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

// kill the 255+ character identifier warning.  Templates tend to exceed that easily.
#pragma warning( disable: 4786 )

#include "stationary_adventure_object.h"

// -----------------------------------------------------------------
// flotsam.  Contains wood and sometimes gold.
// -----------------------------------------------------------------
class t_flotsam : public t_stationary_adventure_object
{
public:
	t_flotsam( t_stationary_adventure_object const& source );
	virtual void	activate_trigger( t_army* army, t_adv_map_point const& point, 
		                                   t_direction direction, t_adventure_frame* frame );
	virtual float	ai_value( t_adventure_ai const& ai, t_creature_array const& army, int move_cost ) const;	
	virtual bool	read( std::streambuf& 						stream, 
							   t_qualified_adv_object_type const&	type,
							   int									version );
	virtual bool	write( std::streambuf& stream ) const;	
protected:
	int m_gold;
	int m_wood;
};

#endif // FLOTSAM_H_INCLUDED
